home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 128 21
/
q21.d81
/
t.docs 4
< prev
next >
Wrap
Text File
|
2022-08-28
|
14KB
|
270 lines
* * * THE AUTOBOOT TOOL * * *
The boot sector is a feature which is supposed to launch software off the
disk as soon as the computer is powered up or reset. However, using this
handy feature for your own purposes has been very difficult. The autoboot
tool consists of several modules which makes creation and manipulation of
boot sectors quick and easy. Also, using DISKSERVANT, a boot sector may be
created to be used on a disk drive of any device number.
SPECIAL NOTE to 1581 users: Using the Autoboot Tool, the root directory
will be automatically selected. A boot sector cannot exist under a
subdirectory.
ANALYZE BOOT SECTOR:
This feature will decode the boot sector and display its results on the
screen. First, it indicates if a boot sector is present, if the boot sector
is occupied by a file, or if a "killed" boot sector is present. Also,
you'll be warned if it is not protected from overwriting (not protected by
BAM). In that case use the Protect Sector(s) feature to protect it if
desired. If a boot sector exists, the following information is provided:
1) Additional boot sectors info. The C128 boot system has an option to read
additional blocks off the disk as part of the boot area. These extra
sectors starts at track 1, sector 1, and continue onward from there. It is
possible to place these extra blocks anywhere in the computer's memory. How
many extra blocks to be loaded, the address and memory bank where they are
placed is displayed.
2) Load PRG file: A file name can be specified in the boot sector, and if
present, a PRG file of that name is loaded into bank 0 RAM. The load
address is determined by the load address of the program itself. The file
name (if any) will be displayed along with the load address. The load
address must be sought in the file itself, and if the file can't be read, a
DOS error message is displayed instead of the load address.
3) ML code start: The boot sector must contain some ML code to determine
what the boot sector is supposed to do. It may be a simple JMP instruction
(similar to BASIC SYS), or an elaborate ML program. The start address of
the ML code is not fixed; it is determined by the length of the boot message
(see below) and file name (above). The start address is displayed as an
offset from the start of the boot buffer in the computer's memory. The boot
buffer is at address 2816 ($0b00) in bank 0. To calculate the real start
address of the ML code, add this number to the offset value.
4) Boot message: An optional message can be displayed when a boot is
performed (BOOT xxxx ...). Often, the name of the program to be booted is
displayed, but the message may contain just about anything. The message may
contain control codes which are displayed as RVS characters by the boot
sector analyzer.
5) Command line: Unlike the other information on the analyzer screen, this
is not a feature inherent to C128 boot sectors. DISKSERVANT's Autoboot Tool
contains a provision for creating a command line of your own fancy. Since
this is the kind of boot sectors you are probably most often going to create
yourself, the BASIC command line (if found) is included here.
Hit any key to return to the Autoboot Tool menu.
DUMP SECTOR:
Displays the contents of track 1 sector 0 as ASCII characters, regardless if
it contains a boot sector or not. Control characters are displayed as RVS
codes. A boot sector has the letters "cbm" as the three first characters.
The Dump feature might be useful for revealing things about a boot sector
that would otherwise be difficult to disclose. Also, if the boot sector is
blocked by a program, you might be able to identify the program which causes
the interference.
Hit any key to return to the Autoboot Tool menu.
MAKE BOOT SECTOR:
The objective here is to create a direct mode BASIC program line to be
executed upon booting. All immediate mode BASIC commands can be used, and
the possibilities are limited by imagination and the size of the boot
sector.
When you select Create from the Autoboot Tool menu, you're warned if a boot
sector is already present on the disk, or if the boot sector is taken by a
program or other data. If you wish to preserve an original boot sector, you
should use the Boot T3o File feature first.
Entering the boot message:
Optionally, you can enter a message to be displayed upon boot (BOOTING xxxx
...). There are a total of 239 characters available for the boot message
and command line. Every character of the boot message steals space from the
command line. Just press RETURN without entering anything if you don't want
a boot message.
Please note that you are not limited to plain text; control characters may
also be used. Please refer to the section about RVS codes below for an
overview of the control characters and how they are entered. Also note that
your computer in most cases will be in uppercase/graphics mode (alias
"cursor up" mode) when the boot message is displayed. Text entered as
lowercase will appear as uppercase, and uppercase characters will appear as
graphic symbols. You may circumvent this by entering a RVS n (hold down
CONTROL and press the n key) as the first character. This will put the
computer into lowercase mode (also called "cursor down" mode) when the boot
sector is executed.
IMPORTANT: NEVER use a RVS @ in your boot sectors. A RVS @ will yield an
ASCII code of zero which will effectively end the string or command line.
Malfunction will be inevitable.
Entering the command line:
This is just like entering a command line in the BASIC immediate mode.
Several commands can be used, separated by colons. Loops can be constructed
using FOR-NEXT or DO-LOOP/EXIT. Decisions can me made using IF/THEN/ELSE.
Please note that you are not restricted to the 160 character limit allowed
by the BASIC screen editor. You can use up to 239 characters, minus the
length of the boot message (if any). You may use abbreviated BASIC commands
if necessary. Of course, the BASIC commands you are going to use most often
are BOOT "filename", BLOAD "filename", SYS and RUN "filename".
It is important to use good sense when constructing a command line.
Remember that you are limited to BASIC commands legal in immediate mode.
This means that INPUT, INPUT#, GET and GET# are out. READ/DATA, GOTO and
GOSUB won't work because the command line doesn't contain line numbers.
Also be careful when using IF-THEN. The command line after the THEN
statement will be executed ONLY if the criteria set in the IF statement is
true. On the other hand, any commands following a ELSE statement will be
executed ONLY of the conditions in the IF statement is FALSE. This means
that if several commands are to be executed in either case after an IF-
THEN command, they must all be included twice; once after the THEN command,
and once after the ELSE command.
Control codes (RVS characters) may be entered as part of the command line,
but only inside quotes. Control characters outside quotes will invoke a
SYNTAX ERROR. You may notice that typing a quote character won't invoke
"quote mode". Rather, if you want to include cursor control, insert,
delete, home, clear or return codes, hold down ALT and press the appropriate
key.
You may find it very useful to be able to boot a program from any disk
drive. For example, running a BASIC program from any disk drive is done
like this:
run "program",u(peek(186))
Please note the use of parentheses. The PEEK command must be enclosed in
parentheses for the U specifier to work. Please note that many programs are
poorly programmed and might not be able to run off any other disk drive than
device 8.
EDIT COMMAND LINE:
You may want to edit a command line boot sector for debugging purposes or
other reasons. The boot sector is read off the disk and a check is made to
establish if a valid boot sector really exists and that it contains a
command line. If everything is found to be OK, editing the command line is
just like creating it for the first time. Please refer to the section about
creation of a boot sector above. The boot message cannot be edited.
RUN/64 BOOT SECTOR:
This selection will create a boot sector to lo